/*
 * @(#)DeleteMe.java   1.0   May 24, 2007
 *
 * Copyright 2000-2007 ETH Zurich. All Rights Reserved.
 *
 * This software is the proprietary information of ETH Zurich.
 * Use is subject to license terms.
 *
 * @(#) $Id: DeleteMe.java 457 2007-05-30 07:59:17Z D\aldespin $
 */
package ch.ethz.globis.javaom.methods;

import bsh.Interpreter;

/**
 * @author aldespin
 * @version 1.0
 */
public class DeleteMe {

   public static void main(final String[] args) throws Exception {
      
      // create body
      final StringBuffer body = new StringBuffer();
      body.append("final int c = a*a + b*b;");
      body.append("return c;");
      
      Interpreter interpreter = new Interpreter();

      // set input parameters
      interpreter.set("a", 3);
      interpreter.set("b", 4);

      System.out.print(interpreter.eval(body.toString()));
   }
}
